#!/usr/bin/env python
# -*- coding: utf-8 -*-

"""
Unit Test for HtmlProcessor

@author Wang Qiang
"""

import unittest 
from WebReader import WebReader
from twisted.internet import reactor
from twisted.internet import defer

def stop_reactor(_):
    reactor.stop()

class UnitTest(unittest.TestCase):
    """
    test for WebReader
    """

    def testDecode(self):
        myReader = WebReader('./webs/news/163.xml')
        d = myReader.openLink()
        d.addBoth(stop_reactor)
        reactor.run()
        self.assertEqual(1, 1)
        self.assertTrue(True)
   

if __name__ == '__main__':
    # Test all
    unittest.main()

